<template>
  <div class="center-bottom-view">
    <title-bar
      class="title-bar"
      imgWidth="545px"
      :titleText="titleText"
      :bgUrl="defaultBg"
    ></title-bar>
    <div class="box">
      <div class="left">
        <div class="top">
          <span>双林镇</span>
          <img class="location" src="@/assets/img/location.svg"></img>
        </div>
        <div class="center">
          <div class="tianqi-icon">
            <img class="img" src="@/assets/img/zhenyu.svg" alt="" />
          </div>
          <div class="tianqi-text">
            <div class="number">35°</div>
            <div class="text">阵雨转阴</div>
          </div>
        </div>
        <div class="bottom">
          <template v-for="item in 3" :key="item">
            <div class="icon-item">
              <img class="icon-img" src="@/assets/img/dongfeng2ji.svg" alt="">
              <div class="icon-text">北风2级</div>
            </div>
          </template>
        </div>
      </div>
      <div class="right">
        <template v-for="(item,index) in 7" :key="item">
          <div class="right-item">
            <div class="day">今天</div>
            <div class="day-time">07/05</div>
            <img class="img1" src="@/assets/img/zhenyu.svg" alt="">
            <div class="info1">阵雨</div>
            <div class="line"></div>
            <img class="img2" src="@/assets/img/zhenyu.svg" alt="">
            <div class="info2">阴天</div>
          </div> 
        </template>
      </div>
    </div>
  </div>
</template>
<script setup lang="ts">
import TitleBar from "./common/title-bar.vue";
import defaultBg from "@/assets/img/tianqi-title-bar2.svg";
let titleText = "双林镇北部现代农业产业园小区域降雨情况分析结果";
</script>

<style lang="less" scoped>
.center-bottom-view {
  width: 100%;
  height: 100%;

  position: relative;

  .box {
    position: absolute;
    left: 16px;
    bottom: 0;
    width: 100%;
    height: 184px;
    display: flex;
    .left {
      width: 182px;
      height: 100%;
      background: linear-gradient(
        180deg,
        rgba(3, 201, 136, 0.13),
        rgba(3, 201, 136, 0),
        rgba(3, 201, 136, 0.13)
      );
      color: #fff;
      opacity: 0.8;
      border-radius: 6px;
      border-top: 1px solid transparent;
      .top {
        font-size: 12px;
        font-weight: 350;
        margin-left: 13px;
        margin-top: 10px;
        .location{
          width: 9px;
          height: 9px;
          margin-left: 3px;
        }
      }
      .center {
        margin-top: 16px;
        margin-left: 13px;
        display: flex;
        .tianqi-icon{
          .img{
            width: 71px;
            height: 71px;

          }
        }
        .tianqi-text{
          margin-left: 20px;
          .number{
            font-size: 40px;
          }
          .text{
            font-size: 12px;
          }
        }
      }
      .bottom {
        margin-top: 20px;
        display: flex;
        justify-content: space-evenly;
        .icon-item{
          display: flex;
          flex-direction: column;
          justify-content: center;
          align-items: center;
          .icon-img{
            width: 18px;
            height: 18px;
          }
          .icon-text{
            font-size: 12px;
          }
        }
      }
    }
    .right{
      margin-left: 30px;
      display: flex;
      .right-item{
        width: 76px;
        height: 100%;
        margin-right: 15px;
        opacity:0.8;
        border-radius: 2px;
        box-shadow: 0px 0px 6px 0px rgb(3, 230, 156);
        display: flex;
        flex-direction: column;
        align-items: center;
        font-size: 12px;
        color: #fff;
        border-top: 1px solid transparent; 
        .day{
          margin-top: 7px;
        }
        .day-time{
          margin-top: 3px;
          color: rgb(194,197,197);
        }
        .img1{
          margin-top: 7px;
          width: 27px;
          height: 27px;
        }
        .info1{
          
        }
        .line{
          margin-top:9px;
          width: 1px;
          height: 24px;
          background-color: #fff;
        }
        .img2{
          margin-top:9px;
          width: 27px;
          height: 27px;
        }
        .info2{
          margin-top:3px;
          color: rgb(194,197,197);
        }
      }
    }
  }
}
</style>
